<%@ page language="java" contentType="text/html; charset=UTF-8"
    pageEncoding="UTF-8"%>
<%@include file="/common/common.jsp" %>
<html>
<head>
<title></title>
<link href="${backPath}/images/skin.css" rel="stylesheet" type="text/css" />
<meta http-equiv="Content-Type" content="text/html; charset=gb2312" />
<style type="text/css">
<!--
body {
	font-size: 12px;
	margin-left: 0px;
	margin-top: 0px;
	margin-right: 0px;
	margin-bottom: 0px;
	background-color: #EEF2FB;
}

.STYLE1 {font-size: 12px}
.STYLE4 {
	font-size: 12px;
	color: #1F4A65;
	font-weight: bold;
}

a:link {
	font-size: 12px;
	color: #06482a;
	text-decoration: none;

}
a:visited {
	font-size: 12px;
	color: #06482a;
	text-decoration: none;
}
a:hover {
	font-size: 12px;
	color: #FF0000;
	text-decoration: underline;
}
a:active {
	font-size: 12px;
	color: #FF0000;
	text-decoration: none;
}
.STYLE7 {font-size: 12}

-->
</style>
<script type="text/javascript" language="javascript">
var  highlightcolor='#E6EDF2';
//此处clickcolor只能用win系统颜色代码才能成功,如果用#xxxxxx的代码就不行,还没搞清楚为什么:(
var  clickcolor='#51b2f6';
function  changeto(){
source=event.srcElement;
if  (source.tagName=="TR"||source.tagName=="TABLE")
return;
while(source.tagName!="TD")
source=source.parentElement;
source=source.parentElement;
cs  =  source.children;
//alert(cs.length);
if  (cs[1].style.backgroundColor!=highlightcolor&&source.id!="nc"&&cs[1].style.backgroundColor!=clickcolor)
for(i=0;i<cs.length;i++){
	cs[i].style.backgroundColor=highlightcolor;
}
}

function  changeback(){
if  (event.fromElement.contains(event.toElement)||source.contains(event.toElement)||source.id=="nc")
return
if  (event.toElement!=source&&cs[1].style.backgroundColor!=clickcolor)
//source.style.backgroundColor=originalcolor
for(i=0;i<cs.length;i++){
	cs[i].style.backgroundColor="";
}
}



//全选功能
function selectAll(){
	var ids=document.getElementsByName("ids");
	var chbAll=document.getElementById("chbAll");

	for(i=0;i<ids.length;i++){
		ids[i].checked=chbAll.checked;
		}
	
}

//删除所有或选择中的留言
function delAll(){
	if(confirm('确定要删除吗？'))
	 document.forms["lvs"].submit();
	
}
</script>
</head>
<body>
<table width="100%" border="0" cellpadding="0" cellspacing="0">
  <tr>
    <td width="17" valign="top" background="${backPath}/images/mail_leftbg.gif"><img src="${backPath}/images/left-top-right.gif" width="17" height="29" /></td>

    <td valign="top" background="${backPath}/images/content-bg.gif"><table width="100%" height="31" border="0" cellpadding="0" cellspacing="0" class="left_topbg" id="table2">
      <tr>
        <td height="31"><div class="titlebt">留言信息</div></td>
      </tr>
    </table></td>
    <td width="16" valign="top" background="${backPath}/images/mail_rightbg.gif"><img src="${backPath}/images/nav-right-bg.gif" width="16" height="29" /></td>
  </tr>
  <tr>

    <td valign="middle" background="${backPath}/images/mail_leftbg.gif">&nbsp;</td>
    <td valign="top" bgcolor="#F7F8F9"><table width="100%" border="0" align="center" cellpadding="0" cellspacing="0">
  <tr>
    <td height="30"><table width="100%" border="0" cellspacing="0" cellpadding="0">
      <tr>
        <td width="15" height="30"><img src="${backPath}/images/list/tab_031.gif" width="15" height="30" /></td>
        <td  background="${backPath}/images/list/tab_051.gif"><img src="${backPath}/images/list/311.gif" width="16" height="16" /> <span class="STYLE4">留言列表</span></td>
        
        <td align="right" background="${backPath}/images/list/tab_051.gif" width="300" >
        <form action="${cardPath}/listview_lv.action" method="post" >
<span class="STYLE1" >状态：</span>

          <select name="state" style="font-size:12px">
            <option value="0">未审核</option>
            <option value="1">已审核</option>
            <option value="2">已回复</option>
          </select>
          <input type="submit" name="search" id="search" class="STYLE1"  value="查询">
          </td>
</form>
        <td width="250" background="${backPath}/images/list/tab_051.gif">

        <table border="0" align="right" cellpadding="0" cellspacing="0">
            <tr>
              <td width="60"><table width="87%" border="0" cellpadding="0" cellspacing="0">
                  <tr>
                    <td class="STYLE1"><div align="center">
                        <input type="checkbox" id="chbAll" value="checkbox" onclick="selectAll()" />
                    </div></td>
                    <td class="STYLE1" width="50px"><div align="center">全选</div></td>

                  </tr>
              </table></td>
            
              <td width="52"><table width="88%" border="0" cellpadding="0" cellspacing="0">
                  <tr>
                    <td class="STYLE1"><div align="center"><img src="${backPath}/images/list/083.gif" width="14" height="14" onclick="delAll()" /></div></td>
                    <td class="STYLE1"><div align="center">删除</div></td>
                  </tr>
              </table></td>

            </tr>
        </table></td>
        <td width="14"><img src="${backPath}/images/list/tab_071.gif" width="14" height="30" /></td>
      </tr>
    </table></td>
  </tr>
  <tr>
    <td>
    <table width="100%" border="0" cellspacing="0" cellpadding="0">

      <tr>
        <td width="9" background="${backPath}/images/list/tab_121.gif">&nbsp;</td>
        <td bgcolor="#EEF2FB">
        
        <table width="99%" border="0" align="center" cellpadding="0" cellspacing="1" bgcolor="#9EAEB9" onMouseOver="changeto()"  onmouseout="changeback()">
          
          <tr>
            <td width="6%" height="26" background="${backPath}/images/list/tab_141.gif" class="STYLE1"><div align="center" class="STYLE2 STYLE1">选择</div></td>
            <td width="50%" height="26" background="${backPath}/images/list/tab_141.gif" class="STYLE1"><div align="center" class="STYLE2 STYLE1">留言内容</div></td>
            <td width="18%" height="26" background="${backPath}/images/list/tab_141.gif" class="STYLE1"><div align="center" class="STYLE2">发布时间</div></td>

            <td width="9%" background="${backPath}/images/list/tab_141.gif" class="STYLE1"><div align="center" class="STYLE2">状态</div></td>
            <td width="9%" height="26" background="${backPath}/images/list/tab_141.gif" class="STYLE1"><div align="center" class="STYLE2">查看</div></td>
            <td width="8%" height="26" background="${backPath}/images/list/tab_141.gif" class="STYLE1"><div align="center" class="STYLE2">删除</div></td>
          </tr>
          <form action="${ cardPath}/delAll_lv.action" method="post" name="lvs">
          <c:forEach items="${pager.resultList}" var="lv">
          <tr>
            <td height="18" bgcolor="#FFFFFF"><div align="center" class="STYLE1">
              <input name="ids" type="checkbox" class="STYLE2" value="${lv.leavewordid}" />

            </div></td>
            <td height="18" bgcolor="#FFFFFF"><div align="center" class="STYLE2 STYLE1">${lv.leavewordcontent }</div></td>
            <td height="18" bgcolor="#FFFFFF"><div align="center"  class="STYLE2 STYLE1" >  <fmt:formatDate value="${lv.leavewordtime}"/>   </div></td>
            <td bgcolor="#FFFFFF">
             <c:if test="${lv.leavewordstate==0}">
            <div align="center"  class="STYLE2 STYLE1">未审核</div>
            </c:if>
            <c:if test="${lv.leavewordstate==1}">
            <div align="center"  class="STYLE2 STYLE1">已审核</div>
            </c:if>
            <c:if test="${lv.leavewordstate==2}">
            <div align="center"  class="STYLE2 STYLE1">已回复</div>
            </c:if>
            </td>
            <td height="18" bgcolor="#FFFFFF"><div align="center"><img src="${backPath}/images/list/037.gif" width="9" height="9" /><span class="STYLE1"> [<a href="view_lv.action?id=${lv.leavewordid }">查看</a>]</span></div></td>

            <td height="18" bgcolor="#FFFFFF"><div align="center"><span class="STYLE2"><img src="${backPath}/images/list/010.gif" width="9" height="9" /> </span><span class="STYLE1">[</span><a href="del_lv.action?id=${lv.leavewordid }" onclick="return confirm('确定要删除吗？');">删除</a><span class="STYLE1">]</span></div></td>
          </tr>
         </c:forEach>   
         </table>
         </form>
         </td>
        <td width="9" background="${backPath}/images/list/tab_161.gif">&nbsp;</td>
      </tr>
    </table></td>
  </tr>
  <tr>
    <td height="29"><table width="100%" border="0" cellspacing="0" cellpadding="0">
      <tr>

        <td width="15" height="29"><img src="${backPath}/images/list/tab_201.gif" width="15" height="29" /></td>
        <td background="${backPath}/images/list/tab_211.gif"><table width="100%" border="0" cellspacing="0" cellpadding="0">
          <tr>
            <td width="25%" height="29" nowrap="nowrap"><span class="STYLE1">共${pager.rowCount}条纪录，当前第${pager.pageNo}/${pager.pageCount}页，每页${pager.pageSize}条纪录</span></td>
            <td width="75%" valign="top" class="STYLE1"><div align="right">
              <table width="352" height="20" border="0" cellpadding="0" cellspacing="0">
                <tr>
                  <td width="62" height="22" valign="middle"><div align="right"><a href="${cardPath}/listview_lv.action?pageNo=${pager.firstPageNo}&state=${state}" ><img src="${backPath}/images/list/first1.gif" width="39" height="17" /></a></div></td>
                  <td width="50" height="22" valign="middle"><div align="right"><a href="${cardPath}/listview_lv.action?pageNo=${pager.prePageNo}&state=${state}" ><img src="${backPath}/images/list/back1.gif" width="45" height="17" /></a></div></td>
                  <td width="54" height="22" valign="middle"><div align="right"><a href="${cardPath}/listview_lv.action?pageNo=${pager.nextPageNo}&state=${state}" ><img src="${backPath}/images/list/next1.gif" width="45" height="17" /></a></div></td>
                  <td width="49" height="22" valign="middle"><div align="right"><a href="${cardPath}/listview_lv.action?pageNo=${pager.lastPageNo}&state=${state}" ><img src="${backPath}/images/list/last1.gif" width="39" height="17" /></a></div></td>
                  <td width="59" height="22" valign="middle"><div align="right">转到第</div></td>
                  <form action="${cardPath}/listview_lv.action" method="post" name="goF">
                  <td width="25" height="22" valign="middle"><span class="STYLE7">
                    <input name="pageNo" type="text" class="STYLE1" style="height:15px; width:25px;" size="5" />
                   <input name="state" type="hidden" value="${state }" />
                  </span></td>
                  <td width="23" height="22" valign="middle">页</td>
                  <td width="30" height="22" valign="middle"><img src="${backPath}/images/list/go1.gif" width="39" height="17" onclick="goF.submit();"/></td>
                </form>
                </tr>
              </table>
            </div></td>
          </tr>
        </table></td>
        <td width="14"><img src="${backPath}/images/list/tab_221.gif" width="14" height="29" /></td>
      </tr>
    </table></td>

  </tr>
</table></td>
    <td background="${backPath}/images/mail_rightbg.gif">&nbsp;</td>
  </tr>
  <tr>
    <td valign="bottom" background="${backPath}/images/mail_leftbg.gif"><img src="${backPath}/images/buttom_left2.gif" width="17" height="17" /></td>
    <td background="${backPath}/images/buttom_bgs.gif"><img src="${backPath}/images/buttom_bgs.gif" width="17" height="17"></td>
    <td valign="bottom" background="${backPath}/images/mail_rightbg.gif"><img src="${backPath}/images/buttom_right2.gif" width="16" height="17" /></td>
  </tr>

</table>
</body>
</html>